﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="ucChangePass.ascx.cs" Inherits="Client_UserControl_ucChangePass" %>
<table cellpadding="0" cellspacing="0" border="0" width="100%">
    <tr>
        <td class="clsRegisterTitle">
            Change Password
        </td>
    </tr>
    <tr>
        <td style="padding: 5px 7px 5px 7px; text-align: left;">
            <asp:UpdatePanel ID="UpdatePanel1" runat="server">
                <ContentTemplate>
                    <table border="0" cellpadding="0" cellspacing="3">
                        <tr>
                            <td>
                            </td>
                            <td>
                            </td>
                        </tr>
                        <tr>
                            <td align="right" style="width: 200px">
                                Email Address:
                            </td>
                            <td align="left">
                                <asp:TextBox ID="txtEmail" runat="server" CssClass="txtRegisterReq" Enabled="false" Width="200px"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td align="right">
                                Old Password:
                            </td>
                            <td>
                                <asp:TextBox ID="txtOldPass" runat="server" TextMode="Password" ToolTip="Input password"
                                    CssClass="txtRegisterReq" Width="200px"></asp:TextBox>
                                &nbsp;<asp:RequiredFieldValidator ID="RequiredFieldValidator2" ControlToValidate="txtPassword"
                                    runat="server" ErrorMessage="*" Display="Dynamic" ValidationGroup="grpPwd"></asp:RequiredFieldValidator></td>
                        </tr>
                        <tr>
                            <td align="right">
                                New Password:
                            </td>
                            <td>
                                <asp:TextBox ID="txtPassword" runat="server" TextMode="Password" ToolTip="Input password"
                                    CssClass="txtRegisterReq" Width="200px"></asp:TextBox>
                                &nbsp;<asp:RequiredFieldValidator ID="RequiredFieldValidator1" ControlToValidate="txtPassword"
                                    runat="server" ErrorMessage="*" Display="Dynamic" ValidationGroup="grpPwd"></asp:RequiredFieldValidator>&nbsp;<asp:RegularExpressionValidator ID="RegularExpressionValidator4" runat="server"
                                    ControlToValidate="txtPassword" Display="Dynamic" ErrorMessage="Password too short"
                                    SetFocusOnError="True" ValidationExpression="[0-9a-zA-Z]{5,}" ValidationGroup="grpPwd"></asp:RegularExpressionValidator></td>
                        </tr>
                        <tr>
                            <td align="right">
                                Confirm New Password:
                            </td>
                            <td>
                                <asp:TextBox ID="txtRePassword" runat="server" TextMode="Password" ToolTip="Retype your password"
                                    CssClass="txtRegisterReq" Width="200px"></asp:TextBox>
                                &nbsp;<asp:RequiredFieldValidator ID="requireRePassword" ControlToValidate="txtRePassword"
                                    runat="server" ErrorMessage="*" Display="Dynamic" ValidationGroup="grpPwd"></asp:RequiredFieldValidator>&nbsp;
                                <asp:CompareValidator ID="CompareValidator1" runat="server" ErrorMessage="Passwords do not match. "
                                    Display="Dynamic" ControlToCompare="txtPassword" ControlToValidate="txtRePassword"
                                    ValidationGroup="grpPwd"></asp:CompareValidator>
                            </td>
                        </tr>
                        <tr>
                            <td colspan="2">
                                <asp:Label ID="lblMessage" runat="server" ForeColor="Red"></asp:Label>
                            </td>
                        </tr>
                    </table>
                </ContentTemplate>
                <Triggers>
                    <asp:AsyncPostBackTrigger ControlID="btnSubmit" EventName="Click" />
                </Triggers>
            </asp:UpdatePanel>
        </td>
    </tr>
    <tr>
        <td align="center" style="padding-top: 10px;">
            <%--<asp:ImageButton ID="cmdSubmit" runat="server" ToolTip="Save" ImageUrl="~/images/btnRegister.png"
                 ValidationGroup="grpRegister" />--%>
            <asp:Button ID="btnSubmit" runat="server" SkinID="btnSubmit" ValidationGroup="grpPwd"
                Text="Save" onclick="btnSubmit_Click" />
        </td>
    </tr>
    <tr>
        <td align="center" style="padding-top: 5px;">
            <asp:UpdateProgress ID="updatePrgReg" runat="server">
                <ProgressTemplate>
                    <asp:Image ID="imgLoading" runat="server" ToolTip="Loading..." ImageUrl="~/images/loadingAnimation.gif"
                        Style="border-width: 0px;" />
                </ProgressTemplate>
            </asp:UpdateProgress>
        </td>
    </tr>
</table>
